/*
 * Copyright (c) 2006, 2022, webrx.cn All rights reserved.
 *
 */
package cn;

/**
 * <p>Project: javase2203 - Reflection3
 * <p>Powered by webrx On 2022-08-11 17:39:02
 *
 * @author webrx [webrx@126.com]
 * @version 1.0
 * @since 17
 */
public class Reflection3 {
    public static void main(String[] args) throws Exception {
        //1 反射类
        Class<?> c1 = Class.forName("cn.Book");
        System.out.println(c1);

        Class<Book> c2 = Book.class;
        System.out.println(c2);

        System.out.println(c1 == c2);

        var c3 = new Book().getClass();
        System.out.println(c3);
        Class<?> c4 = new Book().getClass();
        System.out.println(c4);
        Class<? extends Book> c5 = new Book().getClass();
        System.out.println(c5);

        System.out.println(c1 == c5);
    }
}
